package com.nuanshui.heatedloan.module.features;

import com.alibaba.dubbo.config.annotation.Reference;
import com.nuanshui.heatedloan.constant.GlobalParam;
import com.nuanshui.heatedloan.constant.TransactionManagerType;
import com.nuanshui.heatedloan.module.model.FeatureAttribute;
import com.nuanshui.heatedloan.module.model.ModuleIdConstant;
import com.nuanshui.heatedloan.userinfo.facade.UserQueryService;
import com.nuanshui.heatedloan.userinfo.facade.UserService;
import org.springframework.beans.factory.config.ConfigurableBeanFactory;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

@FeatureAttribute(moduleId = ModuleIdConstant.FEATURE_TYPE_ICON)
@Service
@Transactional(readOnly = true, value = TransactionManagerType.MODULE_TRANSACTION_MANAGER)
@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE)
public class IconFeature extends BaseFeature {


    @Reference(url = GlobalParam.USER_DUBBO_SERVER, timeout = GlobalParam.DUBBO_SERVER_TIME_OUT,version = GlobalParam.BASESERVICE_DUBBO_SERVER_VERSION)
    private UserService userService;

    @Reference(url = GlobalParam.USER_DUBBO_SERVER, timeout = GlobalParam.DUBBO_SERVER_TIME_OUT,version = GlobalParam.BASESERVICE_DUBBO_SERVER_VERSION)
    private UserQueryService userQueryService;

    @Override
    public void internalHandleFeature() {
    }

    @Override
    public int getModuleId() {
        return ModuleIdConstant.FEATURE_TYPE_ICON;
    }

}
